# llm_enhancement/prompts.py

# Inspired by EasyRec: To generate a rich textual description for an item.
ITEM_PROFILE_PROMPT = """
You are an expert recommender system assistant. Based on the following item metadata, please generate a concise, descriptive profile (under 50 words) that captures its key features and suggests the type of user who would be interested in it. Your output must be a single JSON object.

Metadata:
{metadata_json}

JSON Output:
{{
  "summarization": "Your generated profile text here.",
  "reasoning": "Your brief reasoning here."
}}
"""

# Inspired by "Bridging the User-side...": To infer user interests from their interaction history.
USER_PROFILE_PROMPT = """
You are an expert recommender system assistant. Based on the profile of items a user has interacted with, please generate a concise summary of the user's preferences and interests (under 50 words). Your output must be a single JSON object.

Item Profiles this user liked:
- {item_profiles_str}

JSON Output:
{{
  "summarization": "Your summary of the user's profile here.",
  "reasoning": "Your brief reasoning here."
}}
"""

# Inspired by CSRec and CKG-LLMA: To generate commonsense relations with a confidence score.
# INNOVATION: This prompt explicitly asks for a confidence score, which is the core idea from CKG-LLMA.
COMMONSENSE_RELATION_PROMPT = """
You are a knowledge graph expert. For the following pair of items, please determine their commonsense relationship. The possible relationships are 'Complementary' (often bought together), 'Substitute' (can replace each other), or 'Irrelevant'.

Also, provide a confidence score between 0.0 and 1.0 indicating how certain you are of this relationship, and a brief justification.

Item 1: "{item_1_title}"
Item 2: "{item_2_title}"

Output your answer in a strict JSON format without any other text. Example:
{{
  "relationship": "Complementary",
  "confidence": 0.9,
  "justification": "A phone case is a common accessory for a new smartphone."
}}

JSON Output:
"""
